.class public Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;
.super Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;
.source "DlnaDeviceChooseMusicAdapter.java"


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;
    }
.end annotation


# instance fields
.field private i:Ljava/text/SimpleDateFormat;

.field private j:Les/l10;

.field private k:Ljava/lang/String;


# direct methods
.method public constructor <init>(Landroid/content/Context;Landroid/os/Handler;Les/l10;)V
    .locals 0

    .line 1
    invoke-direct {p0, p1, p2}, Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;-><init>(Landroid/content/Context;Landroid/os/Handler;)V

    .line 2
    new-instance p1, Ljava/text/SimpleDateFormat;

    const-string p2, "yyyy-MM-dd"

    invoke-direct {p1, p2}, Ljava/text/SimpleDateFormat;-><init>(Ljava/lang/String;)V

    iput-object p1, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->i:Ljava/text/SimpleDateFormat;

    .line 3
    iput-object p3, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->j:Les/l10;

    const-string p1, "music://"

    const/4 p2, 0x0

    .line 4
    invoke-virtual {p0, p1, p2}, Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;->c(Ljava/lang/String;Z)V

    return-void
.end method

.method static synthetic a(Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;)Les/l10;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->j:Les/l10;

    return-object p0
.end method


# virtual methods
.method public onBindViewHolder(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)V
    .locals 4

    .line 1
    check-cast p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;

    .line 2
    invoke-virtual {p0, p2}, Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;->getItem(I)Lcom/estrongs/fs/g;

    move-result-object p2

    if-nez p2, :cond_0

    return-void

    .line 3
    :cond_0
    iget-object v0, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->j:Les/l10;

    if-nez v0, :cond_1

    return-void

    .line 4
    :cond_1
    invoke-virtual {v0}, Les/l10;->c()Ljava/lang/String;

    move-result-object v0

    iput-object v0, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->k:Ljava/lang/String;

    .line 5
    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    const/16 v1, 0x8

    if-nez v0, :cond_3

    .line 6
    invoke-interface {p2}, Lcom/estrongs/fs/g;->d()Ljava/lang/String;

    move-result-object v0

    iget-object v2, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->k:Ljava/lang/String;

    invoke-virtual {v0, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_2

    .line 7
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->e:Landroid/widget/ImageView;

    const/4 v1, 0x0

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setVisibility(I)V

    .line 8
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->e:Landroid/widget/ImageView;

    iget-object v1, p0, Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;->d:Landroid/content/Context;

    invoke-virtual {v1}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v1

    const v2, 0x7f08056f

    invoke-virtual {v1, v2}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    iget-object v2, p0, Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;->d:Landroid/content/Context;

    .line 9
    invoke-virtual {v2}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v2

    const v3, 0x7f06009c

    invoke-virtual {v2, v3}, Landroid/content/res/Resources;->getColor(I)I

    move-result v2

    .line 10
    invoke-static {v1, v2}, Les/fy;->a(Landroid/graphics/drawable/Drawable;I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setImageDrawable(Landroid/graphics/drawable/Drawable;)V

    goto :goto_0

    .line 11
    :cond_2
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->e:Landroid/widget/ImageView;

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setVisibility(I)V

    goto :goto_0

    .line 12
    :cond_3
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->e:Landroid/widget/ImageView;

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setVisibility(I)V

    .line 13
    :goto_0
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->a:Landroid/widget/ImageView;

    invoke-static {p2, v0}, Lcom/estrongs/android/icon/loader/c;->a(Lcom/estrongs/fs/g;Landroid/widget/ImageView;)V

    .line 14
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->b:Landroid/widget/TextView;

    invoke-interface {p2}, Lcom/estrongs/fs/g;->getName()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    .line 15
    iget-object v0, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->c:Landroid/widget/TextView;

    invoke-interface {p2}, Lcom/estrongs/fs/g;->length()J

    move-result-wide v1

    invoke-static {v1, v2}, Lcom/estrongs/fs/util/f;->g(J)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    .line 16
    iget-object v0, p0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->i:Ljava/text/SimpleDateFormat;

    invoke-interface {p2}, Lcom/estrongs/fs/g;->lastModified()J

    move-result-wide v1

    invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/text/SimpleDateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v0

    .line 17
    iget-object v1, p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;->d:Landroid/widget/TextView;

    invoke-virtual {v1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    .line 18
    iget-object p1, p1, Landroidx/recyclerview/widget/RecyclerView$ViewHolder;->itemView:Landroid/view/View;

    new-instance v0, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$a;

    invoke-direct {v0, p0, p2}, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$a;-><init>(Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;Lcom/estrongs/fs/g;)V

    invoke-virtual {p1, v0}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    return-void
.end method

.method public bridge synthetic onCreateViewHolder(Landroid/view/ViewGroup;I)Landroidx/recyclerview/widget/RecyclerView$ViewHolder;
    .locals 0

    .line 1
    invoke-virtual {p0, p1, p2}, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;->onCreateViewHolder(Landroid/view/ViewGroup;I)Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;

    move-result-object p1

    return-object p1
.end method

.method public onCreateViewHolder(Landroid/view/ViewGroup;I)Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;
    .locals 2

    .line 2
    new-instance p1, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;

    iget-object p2, p0, Lcom/estrongs/android/pop/app/filetransfer/adapter/AbsSelectFileAdapter;->d:Landroid/content/Context;

    invoke-static {p2}, Landroid/view/LayoutInflater;->from(Landroid/content/Context;)Landroid/view/LayoutInflater;

    move-result-object p2

    const v0, 0x7f0c00cc

    const/4 v1, 0x0

    invoke-virtual {p2, v0, v1}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;)Landroid/view/View;

    move-result-object p2

    invoke-direct {p1, p0, p2}, Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter$b;-><init>(Lcom/estrongs/android/ui/dlna/adapter/DlnaDeviceChooseMusicAdapter;Landroid/view/View;)V

    return-object p1
.end method
